home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1994-07-15 | 2.5 KB | [TEXT/MPS ] |
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
You can browse this item here: ICON.LDEF.c
Confidence | Program | Detection | Match Type | Support
|
---|
66%
| dexvert
| Compact Compressed (Unix) (archive/compact)
| ext
| Supported |
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Fri Jul 15 13:00:00 1994, modified Fri Jul 15 13:00:00 1994, creator 'MPS ', type ASCII, 1881 bytes "ICON.LDEF.c" , at 0x7d9 482 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
74%
| TrID
| Macintosh plain text (MacBinary)
| default
| |
25%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [TEXT] |
macFileCreator | [MPS ] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0b 49 43 4f 4e 2e 4c | 44 45 46 2e 63 00 00 00 |..ICON.L|DEF.c...|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4d 50 53 | 20 01 00 00 00 00 00 00 |.TEXTMPS| .......|
|00000050| 00 00 00 00 00 07 59 00 | 00 01 e2 aa 4c 71 10 aa |......Y.|....Lq..|
|00000060| 4c 71 10 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |Lq......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 bc 77 00 00 |........|.....w..|
|00000080| 2f 2a 0d 20 43 4f 50 59 | 52 49 47 48 54 20 28 43 |/*. COPY|RIGHT (C|
|00000090| 29 20 31 39 38 34 2d 31 | 39 39 30 20 41 70 70 6c |) 1984-1|990 Appl|
|000000a0| 65 20 43 6f 6d 70 75 74 | 65 72 2c 49 6e 63 2e 0d |e Comput|er,Inc..|
|000000b0| 20 41 6c 6c 20 72 69 67 | 68 74 73 20 72 65 73 65 | All rig|hts rese|
|000000c0| 72 76 65 64 0d 2a 2f 0d | 0d 23 69 6e 63 6c 75 64 |rved.*/.|.#includ|
|000000d0| 65 09 3c 74 79 70 65 73 | 2e 68 3e 0d 23 69 6e 63 |e.<types|.h>.#inc|
|000000e0| 6c 75 64 65 09 3c 6d 65 | 6d 6f 72 79 2e 68 3e 0d |lude.<me|mory.h>.|
|000000f0| 23 69 6e 63 6c 75 64 65 | 09 3c 6d 65 6e 75 73 2e |#include|.<menus.|
|00000100| 68 3e 0d 23 69 6e 63 6c | 75 64 65 09 3c 72 65 73 |h>.#incl|ude.<res|
|00000110| 6f 75 72 63 65 73 2e 68 | 3e 0d 23 69 6e 63 6c 75 |ources.h|>.#inclu|
|00000120| 64 65 09 3c 6c 69 73 74 | 73 2e 68 3e 0d 23 69 6e |de.<list|s.h>.#in|
|00000130| 63 6c 75 64 65 09 3c 54 | 6f 6f 6c 55 74 69 6c 73 |clude.<T|oolUtils|
|00000140| 2e 68 3e 0d 0d 23 69 6e | 63 6c 75 64 65 09 22 52 |.h>..#in|clude."R|
|00000150| 65 73 45 64 2e 68 22 0d | 0d 23 64 65 66 69 6e 65 |esEd.h".|.#define|
|00000160| 20 49 63 6f 6e 53 69 7a | 65 20 31 32 38 0d 0d 70 | IconSiz|e 128..p|
|00000170| 61 73 63 61 6c 20 76 6f | 69 64 20 44 72 61 77 49 |ascal vo|id DrawI|
|00000180| 63 6f 6e 20 28 52 65 63 | 74 20 2a 6c 52 65 63 74 |con (Rec|t *lRect|
|00000190| 2c 20 48 61 6e 64 6c 65 | 20 74 68 65 49 63 6f 6e |, Handle| theIcon|
|000001a0| 29 0d 0d 7b 0d 69 66 20 | 28 53 69 7a 65 52 65 73 |)..{.if |(SizeRes|
|000001b0| 6f 75 72 63 65 28 74 68 | 65 49 63 6f 6e 29 20 3e |ource(th|eIcon) >|
|000001c0| 3d 20 49 63 6f 6e 53 69 | 7a 65 29 0d 09 50 6c 6f |= IconSi|ze)..Plo|
|000001d0| 74 49 63 6f 6e 28 6c 52 | 65 63 74 2c 20 74 68 65 |tIcon(lR|ect, the|
|000001e0| 49 63 6f 6e 29 3b 0d 7d | 0d 0d 2f 2a 20 54 68 69 |Icon);.}|../* Thi|
|000001f0| 73 20 72 6f 75 74 69 6e | 65 20 73 69 6d 70 6c 79 |s routin|e simply|
|00000200| 20 6c 6f 6f 6b 73 20 75 | 70 20 69 6e 20 74 68 65 | looks u|p in the|
|00000210| 20 6c 69 73 74 20 61 74 | 20 74 68 65 20 67 69 76 | list at| the giv|
|00000220| 65 6e 20 63 65 6c 6c 2c | 20 65 78 74 72 61 63 74 |en cell,| extract|
|00000230| 73 20 74 68 65 20 49 44 | 20 61 6e 64 0d 09 67 65 |s the ID| and..ge|
|00000240| 74 73 20 74 68 65 20 72 | 65 73 6f 75 72 63 65 20 |ts the r|esource |
|00000250| 63 61 6c 6c 65 64 20 66 | 6f 72 2e 20 20 52 65 74 |called f|or. Ret|
|00000260| 75 72 6e 73 20 4e 49 4c | 20 69 66 20 6e 6f 74 20 |urns NIL| if not |
|00000270| 66 6f 75 6e 64 2e 20 20 | 4e 6f 74 65 2c 20 74 68 |found. |Note, th|
|00000280| 69 73 20 61 73 73 75 6d | 65 73 0d 09 74 68 65 20 |is assum|es..the |
|00000290| 72 65 73 66 69 6c 65 20 | 69 73 20 73 65 74 20 75 |resfile |is set u|
|000002a0| 70 20 63 6f 72 72 65 63 | 74 6c 79 2e 0d 09 4e 4f |p correc|tly...NO|
|000002b0| 54 45 3a 20 20 54 68 69 | 73 20 69 73 20 75 73 65 |TE: Thi|s is use|
|000002c0| 64 20 62 79 20 62 6f 74 | 68 20 49 43 4f 4e 20 61 |d by bot|h ICON a|
|000002d0| 6e 64 20 49 43 4e 23 20 | 70 69 63 6b 65 72 73 2e |nd ICN# |pickers.|
|000002e0| 20 2a 2f 0d 48 61 6e 64 | 6c 65 20 49 63 6f 6e 46 | */.Hand|le IconF|
|000002f0| 65 74 63 68 20 28 43 65 | 6c 6c 20 6c 43 65 6c 6c |etch (Ce|ll lCell|
|00000300| 2c 20 4c 69 73 74 48 61 | 6e 64 6c 65 20 6c 48 61 |, ListHa|ndle lHa|
|00000310| 6e 64 6c 65 2c 20 73 68 | 6f 72 74 20 2a 69 64 2c |ndle, sh|ort *id,|
|00000320| 20 42 6f 6f 6c 65 61 6e | 20 2a 77 61 73 4c 6f 61 | Boolean| *wasLoa|
|00000330| 64 65 64 29 0d 7b 0d 09 | 73 68 6f 72 74 09 09 09 |ded).{..|short...|
|00000340| 09 65 72 72 3b 0d 09 73 | 68 6f 72 74 20 09 09 09 |.err;..s|hort ...|
|00000350| 6c 65 6e 20 3d 20 32 3b | 0d 09 48 61 6e 64 6c 65 |len = 2;|..Handle|
|00000360| 09 09 09 74 65 6d 70 48 | 20 3d 20 6e 69 6c 3b 0d |...tempH| = nil;.|
|00000370| 09 50 69 63 6b 48 61 6e | 64 6c 65 20 09 74 65 6d |.PickHan|dle .tem|
|00000380| 70 50 69 63 6b 3b 0d 09 | 0d 09 4c 47 65 74 43 65 |pPick;..|..LGetCe|
|00000390| 6c 6c 28 28 50 74 72 29 | 69 64 2c 20 26 6c 65 6e |ll((Ptr)|id, &len|
|000003a0| 2c 20 6c 43 65 6c 6c 2c | 20 6c 48 61 6e 64 6c 65 |, lCell,| lHandle|
|000003b0| 29 3b 09 09 09 2f 2a 20 | 47 65 74 20 74 68 65 20 |);.../* |Get the |
|000003c0| 49 44 20 66 72 6f 6d 20 | 74 68 65 20 6c 69 73 74 |ID from |the list|
|000003d0| 2e 09 2a 2f 0d 09 69 66 | 20 28 6c 65 6e 20 3d 3d |..*/..if| (len ==|
|000003e0| 20 32 29 20 7b 09 09 09 | 09 09 09 09 09 09 09 09 | 2) {...|........|
|000003f0| 09 09 09 09 09 2f 2a 20 | 49 44 20 6d 75 73 74 20 |...../* |ID must |
|00000400| 62 65 20 32 20 62 79 74 | 65 73 2e 09 09 09 09 2a |be 2 byt|es.....*|
|00000410| 2f 0d 09 09 2f 2a 20 4c | 6f 61 64 20 74 68 65 20 |/.../* L|oad the |
|00000420| 72 65 73 6f 75 72 63 65 | 20 73 69 6e 63 65 20 77 |resource| since w|
|00000430| 65 20 77 61 6e 74 20 74 | 6f 20 64 72 61 77 20 69 |e want t|o draw i|
|00000440| 74 2e 20 09 09 09 09 09 | 09 09 09 09 09 09 09 09 |t. .....|........|
|00000450| 09 2a 2f 0d 09 09 74 65 | 6d 70 50 69 63 6b 20 3d |.*/...te|mpPick =|
|00000460| 20 28 50 69 63 6b 48 61 | 6e 64 6c 65 29 28 28 2a | (PickHa|ndle)((*|
|00000470| 6c 48 61 6e 64 6c 65 29 | 2d 3e 72 65 66 43 6f 6e |lHandle)|->refCon|
|00000480| 29 3b 0d 20 20 20 20 74 | 65 6d 70 48 20 3d 20 52 |);. t|empH = R|
|00000490| 45 47 65 74 31 52 65 73 | 6f 75 72 63 65 53 70 65 |EGet1Res|ourceSpe|
|000004a0| 63 69 61 6c 28 28 2a 74 | 65 6d 70 50 69 63 6b 29 |cial((*t|empPick)|
|000004b0| 2d 3e 74 68 65 52 65 73 | 46 69 6c 65 2c 20 28 2a |->theRes|File, (*|
|000004c0| 74 65 6d 70 50 69 63 6b | 29 2d 3e 72 54 79 70 65 |tempPick|)->rType|
|000004d0| 2c 20 2a 69 64 2c 20 77 | 61 73 4c 6f 61 64 65 64 |, *id, w|asLoaded|
|000004e0| 2c 20 26 65 72 72 29 3b | 09 09 0d 09 09 7d 0d 09 |, &err);|.....}..|
|000004f0| 72 65 74 75 72 6e 20 74 | 65 6d 70 48 3b 0d 7d 0d |return t|empH;.}.|
|00000500| 0d 2f 2a 20 54 68 69 73 | 20 69 73 20 74 68 65 20 |./* This| is the |
|00000510| 63 75 73 74 6f 6d 20 64 | 72 61 77 50 72 6f 63 20 |custom d|rawProc |
|00000520| 66 6f 72 20 74 68 65 20 | 6c 69 73 74 20 28 77 68 |for the |list (wh|
|00000530| 69 63 68 20 63 6f 6e 74 | 61 69 6e 73 20 74 68 65 |ich cont|ains the|
|00000540| 20 72 65 73 6f 75 72 63 | 65 20 49 44 27 73 29 2e | resourc|e ID's).|
|00000550| 20 20 49 74 0d 09 73 69 | 6d 70 6c 79 20 64 72 61 | It..si|mply dra|
|00000560| 77 73 20 74 68 65 20 69 | 63 6f 6e 20 69 6e 20 74 |ws the i|con in t|
|00000570| 68 65 20 67 69 76 65 6e | 20 72 65 63 74 20 61 6e |he given| rect an|
|00000580| 64 20 66 72 61 6d 65 73 | 20 61 20 73 65 6c 65 63 |d frames| a selec|
|00000590| 74 69 6f 6e 20 72 65 63 | 74 20 61 72 6f 75 6e 64 |tion rec|t around|
|000005a0| 20 69 74 20 28 69 66 0d | 09 6e 65 63 65 73 73 61 | it (if.|.necessa|
|000005b0| 72 79 29 2e 20 2a 2f 0d | 70 61 73 63 61 6c 20 76 |ry). */.|pascal v|
|000005c0| 6f 69 64 20 20 44 72 61 | 77 43 65 6c 6c 28 73 68 |oid Dra|wCell(sh|
|000005d0| 6f 72 74 20 6d 65 73 73 | 61 67 65 2c 20 42 6f 6f |ort mess|age, Boo|
|000005e0| 6c 65 61 6e 20 6c 53 65 | 6c 65 63 74 2c 20 52 65 |lean lSe|lect, Re|
|000005f0| 63 74 20 2a 6c 52 65 63 | 74 2c 20 50 6f 69 6e 74 |ct *lRec|t, Point|
|00000600| 20 6c 43 65 6c 6c 2c 0d | 20 20 20 20 20 20 20 20 | lCell,.| |
|00000610| 20 20 20 20 20 20 20 20 | 20 20 20 09 09 73 68 6f | | ..sho|
|00000620| 72 74 20 6c 44 61 74 61 | 4f 66 66 73 65 74 2c 20 |rt lData|Offset, |
|00000630| 73 68 6f 72 74 20 6c 44 | 61 74 61 4c 65 6e 2c 20 |short lD|ataLen, |
|00000640| 4c 69 73 74 48 61 6e 64 | 6c 65 20 6c 48 61 6e 64 |ListHand|le lHand|
|00000650| 6c 65 29 0d 7b 0d 09 48 | 61 6e 64 6c 65 20 74 68 |le).{..H|andle th|
|00000660| 65 49 63 6f 6e 3b 0d 09 | 73 68 6f 72 74 20 69 64 |eIcon;..|short id|
|00000670| 3b 0d 09 42 6f 6f 6c 65 | 61 6e 20 77 61 73 4c 6f |;..Boole|an wasLo|
|00000680| 61 64 65 64 3b 0d 09 0d | 09 23 70 72 61 67 6d 61 |aded;...|.#pragma|
|00000690| 09 75 6e 75 73 65 64 20 | 28 6c 44 61 74 61 4f 66 |.unused |(lDataOf|
|000006a0| 66 73 65 74 2c 20 6c 44 | 61 74 61 4c 65 6e 29 09 |fset, lD|ataLen).|
|000006b0| 2f 2a 20 4e 6f 74 20 6e | 65 65 64 65 64 20 68 65 |/* Not n|eeded he|
|000006c0| 72 65 2e 09 09 09 09 09 | 09 09 09 2a 2f 0d 0d 09 |re......|...*/...|
|000006d0| 69 66 20 28 28 6d 65 73 | 73 61 67 65 20 3d 3d 20 |if ((mes|sage == |
|000006e0| 6c 44 72 61 77 4d 73 67 | 29 20 7c 7c 20 28 6d 65 |lDrawMsg|) || (me|
|000006f0| 73 73 61 67 65 20 3d 3d | 20 6c 48 69 6c 69 74 65 |ssage ==| lHilite|
|00000700| 4d 73 67 29 29 20 7b 0d | 09 09 74 68 65 49 63 6f |Msg)) {.|..theIco|
|00000710| 6e 20 3d 20 49 63 6f 6e | 46 65 74 63 68 28 6c 43 |n = Icon|Fetch(lC|
|00000720| 65 6c 6c 2c 20 6c 48 61 | 6e 64 6c 65 2c 20 26 69 |ell, lHa|ndle, &i|
|00000730| 64 2c 20 26 77 61 73 4c | 6f 61 64 65 64 29 3b 0d |d, &wasL|oaded);.|
|00000740| 09 09 44 72 61 77 4c 44 | 45 46 20 28 6d 65 73 73 |..DrawLD|EF (mess|
|00000750| 61 67 65 2c 20 6c 53 65 | 6c 65 63 74 2c 20 6c 52 |age, lSe|lect, lR|
|00000760| 65 63 74 2c 20 74 68 65 | 49 63 6f 6e 2c 20 69 64 |ect, the|Icon, id|
|00000770| 2c 20 22 5c 70 22 2c 20 | 33 32 2c 20 33 32 2c 20 |, "\p", |32, 32, |
|00000780| 44 72 61 77 49 63 6f 6e | 2c 20 6c 48 61 6e 64 6c |DrawIcon|, lHandl|
|00000790| 65 29 3b 0d 09 09 0d 09 | 09 69 66 20 28 28 74 68 |e);.....|.if ((th|
|000007a0| 65 49 63 6f 6e 20 21 3d | 20 6e 69 6c 29 20 26 26 |eIcon !=| nil) &&|
|000007b0| 20 28 21 77 61 73 4c 6f | 61 64 65 64 29 29 0d 09 | (!wasLo|aded))..|
|000007c0| 09 09 48 50 75 72 67 65 | 28 74 68 65 49 63 6f 6e |..HPurge|(theIcon|
|000007d0| 29 3b 0d 09 09 7d 0d 7d | 0d 00 00 00 00 00 00 00 |);...}.}|........|
|000007e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000800| 00 00 01 00 00 00 01 90 | 00 00 00 90 00 00 00 52 |........|.......R|
|00000810| 20 20 20 20 20 20 20 20 | 20 20 50 6c 6f 74 49 63 | | PlotIc|
|00000820| 6f 6e 28 20 72 2c 20 69 | 20 29 3b 0d 20 20 20 20 |on( r, i| );. |
|00000830| 0b 49 43 4f 4e 2e 4c 44 | 45 46 2e 63 02 00 00 00 |.ICON.LD|EF.c....|
|00000840| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000850| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000860| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000870| 00 00 aa 6e eb cc 00 00 | 07 59 00 00 01 e2 20 20 |...n....|.Y.... |
|00000880| 20 20 20 52 54 53 0d 0d | 20 54 4f 20 33 20 44 4f | RTS..| TO 3 DO|
|00000890| 0d 20 20 20 42 65 67 69 | 6e 7b 49 6e 76 61 6c 20 |. Begi|n{Inval |
|000008a0| 76 69 65 77 73 20 6f 6e | 20 67 72 65 79 7d 0d 20 |views on| grey}. |
|000008b0| 20 20 4f 66 66 73 65 74 | 52 65 63 74 28 20 72 2c | Offset|Rect( r,|
|000008c0| 20 72 65 61 6c 44 65 6c | 74 61 2c 20 30 29 3b 0d | realDel|ta, 0);.|
|000008d0| 20 20 20 49 6e 76 61 6c | 52 65 63 74 28 20 72 20 | Inval|Rect( r |
|000008e0| 29 3b 0d 20 20 20 45 6e | 64 3b 0d 45 6e 64 3b 7b |);. En|d;.End;{|
|000008f0| 49 6e 76 61 6c 53 6d 61 | 6c 6c 56 69 65 77 73 7d |InvalSma|llViews}|
|00000900| 00 00 00 48 00 09 4d 6f | 6e 61 63 6f 00 42 02 58 |...H..Mo|naco.B.X|
|00000910| 7f ff 7f ff 00 00 00 b0 | 00 00 00 00 00 00 00 00 |........|........|
|00000920| 00 00 00 00 00 00 00 06 | 00 02 00 27 00 00 03 65 |........|...'...e|
|00000930| 02 58 00 27 00 00 03 65 | 02 58 a3 27 ee c4 00 00 |.X.'...e|.X.'....|
|00000940| 07 27 00 00 07 27 00 00 | 00 00 01 00 00 00 00 1e |.'...'..|........|
|00000950| 00 27 00 00 03 65 02 58 | 00 27 00 00 03 65 02 58 |.'...e.X|.'...e.X|
|00000960| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000970| 00 1e 15 00 80 00 00 00 | 04 31 35 2e 30 12 45 2e |........|.15.0.E.|
|00000980| 54 2e 4f 2e 2f 4d 50 57 | 20 50 72 6f 20 23 31 35 |T.O./MPW| Pro #15|
|00000990| 00 00 01 00 00 00 01 90 | 00 00 00 90 00 00 00 52 |........|.......R|
|000009a0| 00 49 bc fc 0f cc 00 00 | 00 1c 00 52 00 01 4d 50 |.I......|...R..MP|
|000009b0| 53 52 00 01 00 12 76 65 | 72 73 00 00 00 2a 03 ed |SR....ve|rs...*..|
|000009c0| ff ff 00 00 00 00 00 00 | 00 00 03 f0 ff ff 00 00 |........|........|
|000009d0| 00 4c 00 00 00 00 00 02 | ff ff 20 00 00 6e 00 49 |.L......|.. ..n.I|
|000009e0| ba e4 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000009f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+